<template lang="">
  <van-search v-model="value" shape="round" background="#4fc08d" placeholder="请输入搜索关键词"
   @search="onSearch"/>
</template>
<script>
export default {
  data() {
    return {
      value: '',
    }
  },
  methods: {
    onSearch() {
      console.log('搜索', this.value)
      this.$router.push({ path: '/search', query: { keyword: this.value } })
    },
  }
}
</script>
<style lang="">

</style>
